import random
lst1 = []
d1 = {}
[lst1.append(random.randint(1,20)) for i in range(20)]
s = set(lst1)
[d1.update({k:lst1.count(k)}) for k in s]
print(d1)
lst2 = sorted(list(d1.items()),key=lambda x:x[1],reverse=True)
print(lst2)
print(lst2[:3])


# 完成的不错
